<template>
  <div class="zi2">
    <button @click="fun()">点我子组件2向3兄弟传值</button>
    <h1>{{text}}</h1>
  </div>
</template>

<script>
import Eventbus from "@/eventBus/text.js"
export default {
  data(){
    return{
      text:"我是子组件2的数据"
    }
  },
  methods: {
    fun(){
      Eventbus.$emit('zi2Value',this.text);
    }
  },
}
</script>

<style scoped>

</style>